/*            Copyright(c) 2006-2008 Dave Sexton           *
 * http://www.codeplex.com/DocProject                      *
 * http://www.codeplex.com/DocProject/Project/License.aspx *
 ***********************************************************/
using System;
using System.Collections.Generic;
using System.Text;
using DaveSexton.DocProject.Resources;
using EnvDTE;
using EnvDTE80;
using Microsoft.VisualStudio.CommandBars;

namespace DaveSexton.DocProject
{
	public abstract class ToolBarCommand : VSCommand
	{
		#region Public Properties
		public ToolBar ToolBar
		{
			get
			{
				return toolBar;
			}
			internal set
			{
				if (toolBar != null)
					throw new InvalidOperationException(Errors.ToolBarCommandAlreadyAssigned);

				toolBar = value;
			}
		}
		#endregion

		#region Private / Protected
		private ToolBar toolBar;
		#endregion

		#region Constructors
		/// <summary>
		/// Constructs a new instance of the <see cref="ToolBarCommand" /> class for derived classes.
		/// </summary>
		protected ToolBarCommand()
		{
		}
		#endregion
	}
}
